package arkham.util;

/**
 * This class provides some logging methods to output error log info
 * @author ctheng
 *
 */
public class AHLogger {

    private static boolean DEBUG = false;

	public static void error(Object o, String s)
	{
		System.err.println("ERROR (" + o.toString() + ") - " + s);
	}

	public static void error(String s)
	{
		System.err.println("ERROR - " + s);
	}

	public static void warning(Object o, String s)
	{
		System.err.println("WARN  (" + o.toString() + ") - " + s);
	}

	public static void warning(String s)
	{
		System.err.println("WARN  - " + s);
	}

	public static void info(Object o, String s)
	{
		System.out.println("INFO  (" + o.toString() + ") - " + s);
	}

	public static void info(String s)
	{
		System.out.println("INFO  - " + s);
	}

	public static void debug(Object o, String s)
    {
	    if (DEBUG)
	    {
	        System.out.println("DEBUG  (" + o.toString() + ") - " + s);
	    }
    }

    public static void debug(String s)
    {
        if (DEBUG)
        {
            System.out.println("DEBUG  - " + s);
        }
    }
}
